import request from './request'

/**
 * 通过手机号查询医生信息
 * @param {string} phone 手机号码
 * @returns {Promise} 返回医生信息
 */
export function getDoctorByPhone(phone) {
  return request({
    url: '/doctor/doctor/phone/' + phone, 
    method: 'get'
  })
}

/**
 * 获取医生列表
 * @param {Object} params 
 * @returns {Promise}
 */
export const getDoctorList = (params) => {
  return request({
    url: '/doctor/doctor/details',
    method: 'get',
    params
  });
};

/**
 * 修改医生信息
 * @param {Object} data 医生信息对象
 * @returns {Promise}
 */
export const updateDoctor = (data) => {
  return request({
    url: '/doctor/doctor',
    method: 'put',
    data
  });
};



